Skip to content

Conversation

kakakakakku
Copy link
Contributor

@kakakakakku kakakakakku commented Jul 9, 2025

Issue #, if available:
N/A

Description of changes:
Hi😀 Thanks for the useful patterns!

To prevent future deployment issues, I updated the Lambda Python runtime and Powertools version to python3.12.

While testing terraform-lambda-sfn, I noticed that the Lambda runtime version python3.8 was deprecated. Although it's still deployable at the moment, it will not be allowed after October 1, 2025.
https://docs.aws.amazon.com/lambda/latest/dg/lambda-runtimes.html

Check

terraform apply completed successfully and works good.

Warning

Warning is likely caused by the fact that the AWS provider version is currently at v6 (due to >= 4.9 constraint), and data.aws_region.current.name is now a deprecated attribute. There is no functional impact at this time👍

$ terraform apply

╷
│ Warning: Deprecated attribute
│ 
│   on .terraform/modules/lambda_function/outputs.tf line 9, in output "lambda_function_arn_static":
│    9:   value       = local.create && var.create_function && !var.create_layer ? "arn:aws:lambda:${data.aws_region.current.name}:${data.aws_caller_identity.current.account_id}:function:${var.function_name}" : ""
│ 
│ The attribute "name" is deprecated. Refer to the provider documentation for details.
│ 
│ (and one more similar warning elsewhere)
╵

Apply complete! Resources: 20 added, 0 changed, 0 destroyed.

stepfunctions_graph

Thank you😀


By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

publish = true

source_path = "${path.module}/src"

layers = ["arn:aws:lambda:${data.aws_region.current.name}:017000801446:layer:AWSLambdaPowertoolsPython:15"]
layers = ["arn:aws:lambda:${data.aws_region.current.region}:017000801446:layer:AWSLambdaPowertoolsPythonV3-python312-x86_64:19"]
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

@kakakakakku kakakakakku Jul 9, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

note: https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/region

name - (Optional, Deprecated) Full name of the region to select. Use region instead.

╷
│ Warning: Deprecated attribute
│ 
│   on main.tf line 107, in module "lambda_function":
│  107:   layers = ["arn:aws:lambda:${data.aws_region.current.name}:017000801446:layer:AWSLambdaPowertoolsPythonV3-python312-x86_64:19"]
│ 
│ The attribute "name" is deprecated. Refer to the provider documentation for details.
│ 
│ (and 5 more similar warnings elsewhere)
╵

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants